class Solution {
public:
    vector<int> getSneakyNumbers(vector<int>& nums) {
        
        vector<int> vecRet;
        unordered_set<int> has;
        for(int i=0;i<nums.size();++i){
            if(has.count(nums[i])){
                vecRet.push_back(nums[i]);
            }
            has.insert(nums[i]);
        }

        return vecRet;
    }
};
